package com.mkait.thief.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import lombok.Data;

/**
 * 
 * @TableName plugin_punish
 */
@TableName(value ="plugin_punish")
@Data
public class PluginPunish implements Serializable {
    /**
     * 
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 
     */
    @TableField(value = "user_id")
    private Integer userId;

    /**
     * 用于累积
     */
    @TableField(value = "complaint_count")
    private Integer complaintCount;

    /**
     * 
     */
    @TableField(value = "order_count")
    private Integer orderCount;

    /**
     * 
     */
    @TableField(value = "update_at")
    private Integer updateAt;

    /**
     * 
     */
    @TableField(value = "history_count")
    private Integer historyCount;

    /**
     * 
     */
    @TableField(value = "history_money")
    private BigDecimal historyMoney;

    /**
     * 
     */
    @TableField(value = "is_white")
    private Integer isWhite;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        PluginPunish other = (PluginPunish) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
            && (this.getComplaintCount() == null ? other.getComplaintCount() == null : this.getComplaintCount().equals(other.getComplaintCount()))
            && (this.getOrderCount() == null ? other.getOrderCount() == null : this.getOrderCount().equals(other.getOrderCount()))
            && (this.getUpdateAt() == null ? other.getUpdateAt() == null : this.getUpdateAt().equals(other.getUpdateAt()))
            && (this.getHistoryCount() == null ? other.getHistoryCount() == null : this.getHistoryCount().equals(other.getHistoryCount()))
            && (this.getHistoryMoney() == null ? other.getHistoryMoney() == null : this.getHistoryMoney().equals(other.getHistoryMoney()))
            && (this.getIsWhite() == null ? other.getIsWhite() == null : this.getIsWhite().equals(other.getIsWhite()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode());
        result = prime * result + ((getComplaintCount() == null) ? 0 : getComplaintCount().hashCode());
        result = prime * result + ((getOrderCount() == null) ? 0 : getOrderCount().hashCode());
        result = prime * result + ((getUpdateAt() == null) ? 0 : getUpdateAt().hashCode());
        result = prime * result + ((getHistoryCount() == null) ? 0 : getHistoryCount().hashCode());
        result = prime * result + ((getHistoryMoney() == null) ? 0 : getHistoryMoney().hashCode());
        result = prime * result + ((getIsWhite() == null) ? 0 : getIsWhite().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", userId=").append(userId);
        sb.append(", complaintCount=").append(complaintCount);
        sb.append(", orderCount=").append(orderCount);
        sb.append(", updateAt=").append(updateAt);
        sb.append(", historyCount=").append(historyCount);
        sb.append(", historyMoney=").append(historyMoney);
        sb.append(", isWhite=").append(isWhite);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}